home *** CD-ROM | disk | FTP | other *** search
/ Larry Magid's Essential Internet / Larry Magid's Essential Internet (Quarterdeck Corporation)(1995).ISO / qsockpro.qip / PORTALCS.MPS < prev    next >
Text File  |  1995-10-09  |  1KB  |  58 lines

  1. # Portal Compuserve PPP and SLIP script
  2. # Copyright 1995 Quarterdeck Corporation
  3. # 5-9-95
  4.  
  5. STRING username
  6. STRING password
  7. STRING IPaddress
  8. STRING framing
  9.  
  10. #TRACE ON
  11. SetTimeout 90                      # reset maximum script timeout
  12.  
  13. # Get username from access method
  14. CfgGetValue "Username" username
  15. IF result = 0 THEN
  16.     ABORT "Can't load Username from qdeck.ini"
  17. ENDIF
  18.  
  19. # get password from access method
  20. CfgGetValue "Password" password
  21. IF result = 0 THEN
  22.     ABORT "Can't load Password from qdeck.ini"
  23. ENDIF
  24.  
  25. CfgGetValue "Framing" framing
  26. IF result =0 THEN
  27.     ABORT "Cannot load framing value from QDECK.INI!"
  28. ENDIF
  29.  
  30. DELAY 2
  31. CommSend    "%r%r%r"
  32. DELAY 2
  33. CommSend    "+%r"
  34. CommWaitFor "Name:"
  35. CommSend    "portal%r"
  36. CommWaitFor "help:"
  37. CommSend    "ip%r"
  38.  
  39. CommWaitFor "login:"
  40. CommSend    username
  41. CommSend    "%r"            # send carriage return
  42.  
  43. CommWaitFor "password:"
  44. CommSend    password
  45. CommSend    "%r"            # send carriage return
  46.  
  47. IF framing = "MPSLIP" THEN
  48.     PRINT "Getting IP Address for SLIP."
  49.     CommReadIPAddr IPAddress
  50.     IF result < 7 THEN                     # IP Address length test
  51.         ABORT "Missing or invalid IP Address."
  52.     ENDIF
  53.     CfgSetValue "IPAddress" ipaddress
  54.     PRINT "IP Address set to:"; ipaddress
  55. ENDIF
  56.  
  57. END
  58.